/*    */ package com.feeyin.radar.sys.dao.impl;
/*    */ 
/*    */ import com.feeyin.radar.sys.dao.FunctionOperateDAO;
/*    */ import com.feeyin.radar.sys.model.FunctionOperate;
/*    */ import java.util.HashMap;
/*    */ import java.util.List;
/*    */ import java.util.Map;
/*    */ import org.springframework.orm.ibatis.SqlMapClientTemplate;
/*    */ import org.springframework.orm.ibatis.support.SqlMapClientDaoSupport;
/*    */ 
/*    */ public class FunctionOperateDAOImpl extends SqlMapClientDaoSupport
/*    */   implements FunctionOperateDAO
/*    */ {
/*    */   public List getFunctionOperates()
/*    */   {
/* 21 */     return getSqlMapClientTemplate().queryForList("getFunctionOperates");
/*    */   }
/*    */ 
/*    */   public List getFunctionOperatesByRoleIdFunctionId(Integer roleId, Integer functionId)
/*    */   {
/* 26 */     Map map = new HashMap();
/* 27 */     map.put("roleId", roleId);
/* 28 */     map.put("functionId", functionId);
/* 29 */     return getSqlMapClientTemplate().queryForList("getFunctionOperatesByRoleIdFunctionId", map);
/*    */   }
/*    */ 
/*    */   public List getFunctionOperatesByOperateId(Integer operateId) {
/* 33 */     if (operateId == null) return null;
/* 34 */     return getSqlMapClientTemplate().queryForList("getFunctionOperatesByOperateId", operateId);
/*    */   }
/*    */ 
/*    */   public boolean insertFunctionOperate(FunctionOperate functionOperate) {
/* 38 */     Integer result = (Integer)getSqlMapClientTemplate().insert("insertFunctionOperate", functionOperate);
/* 39 */     return result != null;
/*    */   }
/*    */ 
/*    */   public boolean deleteFunctionOperate(Integer roleId)
/*    */   {
/* 44 */     Integer result = Integer.valueOf(getSqlMapClientTemplate().delete("deleteFunctionOperate", roleId));
/* 45 */     return result != null;
/*    */   }
/*    */ }

/* Location:           C:\Users\e547415\MyProject\rone\WEB-INF\classes\
 * Qualified Name:     com.feeyin.radar.sys.dao.impl.FunctionOperateDAOImpl
 * JD-Core Version:    0.6.0
 */